package com.jsaber.postaware;

import org.springframework.beans.BeansException;
import org.springframework.beans.factory.FactoryBean;
import org.springframework.beans.factory.InitializingBean;
import org.springframework.beans.factory.config.BeanPostProcessor;

/**
 * @author : zijia
 * @Description: TODO
 * @date Date : 2021-07-02 10:30
 */
public class MyBeanPostProcessor1 implements BeanPostProcessor {


    @Override
    public Object postProcessBeforeInitialization(Object bean, String beanName) throws BeansException {
        System.out.println("自定义BeanPostProcessor before");
        return bean;
    }


    @Override
    public Object postProcessAfterInitialization(Object bean, String beanName) throws BeansException {
        System.out.println("自定义BeanPostProcessor after");
        return bean;
    }
}
